<!DOCTYPE html>
<html>
    <head>
        <title>Model class concept (js)</title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <script type="text/javascript" src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.8.2.min.js"></script>
        <script type="text/javascript" src="/js/Reg.js"></script>
        <script type="text/javascript" src="/js/Classes.js"></script>
    </head>
    <body>
        <h4>Please run the test in the firebug...</h4>
        <p>View results in the console.</p>
        <script type="text/javascript">
        <!--
       
        /**
         *----------------------------------------------------------------------
         * This is demo of how the model should work
         */
        // JSON mock
        var $assemblies   = {
            "1":{"id":"1","title":"12v power outlet front","fk_module_id":"100002","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"2":{"id":"2","title":"Less 12v power outlet rear","fk_module_id":"100003","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"3":{"id":"3","title":"12v power outlet rear","fk_module_id":"100003","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"4":{"id":"4","title":"Manual Air Conditioning","fk_module_id":"100004","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"5":{"id":"5","title":"Auto Air Conditioning","fk_module_id":"100004","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"6":{"id":"6","title":"Ashtray front","fk_module_id":"100005","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"7":{"id":"7","title":"Audio Pack 1","fk_module_id":"100006","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"8":{"id":"8","title":"Audio Pack 2","fk_module_id":"100006","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"9":{"id":"9","title":"Audio Pack 3","fk_module_id":"100006","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"10":{"id":"10","title":"Audio Pack 4","fk_module_id":"100006","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"11":{"id":"11","title":"Audio Pack 5","fk_module_id":"100006","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"12":{"id":"12","title":"Audio Pack 6","fk_module_id":"100006","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"13":{"id":"13","title":"Axle ratio 3.31","fk_module_id":"100007","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"14":{"id":"14","title":"Axle ratio 3.55","fk_module_id":"100007","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"15":{"id":"15","title":"Axle ratio 3.73","fk_module_id":"100007","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"16":{"id":"16","title":"Axle ratio 4.1","fk_module_id":"100007","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"17":{"id":"17","title":"Brakes","fk_module_id":"100008","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"18":{"id":"18","title":"Cigar lighter front seats","fk_module_id":"100009","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"19":{"id":"19","title":"Less Coming home device","fk_module_id":"100010","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"20":{"id":"20","title":"Coming home device","fk_module_id":"100010","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"21":{"id":"21","title":"Michigan Assembly Plant","fk_module_id":"100012","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"22":{"id":"22","title":"Less Cruise control","fk_module_id":"100013","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"23":{"id":"23","title":"Cruise control","fk_module_id":"100013","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"24":{"id":"24","title":"Cup holders front seats","fk_module_id":"100014","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"25":{"id":"25","title":"Less Cup holders rear seats","fk_module_id":"100015","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"26":{"id":"26","title":"Cup holders rear seats","fk_module_id":"100015","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"27":{"id":"27","title":"Dashboard - Base","fk_module_id":"100016","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"28":{"id":"28","title":"Dashboard - Low","fk_module_id":"100016","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"29":{"id":"29","title":"Dashboard - Mid","fk_module_id":"100016","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"30":{"id":"30","title":"Dashboard - High","fk_module_id":"100016","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"31":{"id":"31","title":"Dashboard - Premium","fk_module_id":"100016","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"32":{"id":"32","title":"Less descent control system","fk_module_id":"100017","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"33":{"id":"33","title":"descent control system","fk_module_id":"100017","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"34":{"id":"34","title":"Less Differential lock rear","fk_module_id":"100018","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"35":{"id":"35","title":"Differential lock rear","fk_module_id":"100018","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"36":{"id":"36","title":"Electronic traction control","fk_module_id":"100019","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"37":{"id":"37","title":"Less Entertainment display screen front","fk_module_id":"100020","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"38":{"id":"38","title":"Base Entertainment display screen front","fk_module_id":"100020","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"39":{"id":"39","title":"High Entertainment display screen front","fk_module_id":"100020","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"40":{"id":"40","title":"Exterior Mirrors Type 1","fk_module_id":"100021","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"41":{"id":"41","title":"Exterior Mirrors Type 2","fk_module_id":"100021","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"42":{"id":"42","title":"Exterior Mirrors Type 3","fk_module_id":"100021","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"43":{"id":"43","title":"Exterior Mirrors Type 4","fk_module_id":"100021","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"44":{"id":"44","title":"Exterior Mirrors Type 5","fk_module_id":"100021","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"45":{"id":"45","title":"Exterior Mirrors Type 6","fk_module_id":"100021","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"46":{"id":"46","title":"Exterior Mirrors Type 7","fk_module_id":"100021","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"47":{"id":"47","title":"Less Floor mats","fk_module_id":"100022","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"48":{"id":"48","title":"Floor mats","fk_module_id":"100022","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"49":{"id":"49","title":"Less Front fog lights","fk_module_id":"100023","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"50":{"id":"50","title":"Front fog lights","fk_module_id":"100023","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"51":{"id":"51","title":"Less Front seat centre armrest","fk_module_id":"100024","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"52":{"id":"52","title":"Front seat centre armrest","fk_module_id":"100024","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"53":{"id":"53","title":"Front Airbags less PABD","fk_module_id":"100025","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"54":{"id":"54","title":"Front Airbags PABD","fk_module_id":"100025","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"55":{"id":"55","title":"Front Bumper Argent","fk_module_id":"100026","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"56":{"id":"56","title":"Front Bumper Painted","fk_module_id":"100026","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"57":{"id":"57","title":"Front Bumper Chrome","fk_module_id":"100026","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"58":{"id":"58","title":"Front Seats Bench Manual 2 Way","fk_module_id":"100027","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"59":{"id":"59","title":"Front Seats Bench Manual 3 Way","fk_module_id":"100027","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"60":{"id":"60","title":"Front Seats Bucket Pass Manual","fk_module_id":"100027","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"61":{"id":"61","title":"Front Seats Bench Power","fk_module_id":"100027","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"62":{"id":"62","title":"Front Seats Bucket Pass Power","fk_module_id":"100027","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"63":{"id":"63","title":"Front Seats Power Memory Heated","fk_module_id":"100027","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"64":{"id":"64","title":"Front Seat Belts Less Centre","fk_module_id":"100028","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"65":{"id":"65","title":"Front Seat Belts + Centre","fk_module_id":"100028","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"66":{"id":"66","title":"Manual Front Windows","fk_module_id":"100029","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"67":{"id":"67","title":"Electric Front Windows","fk_module_id":"100029","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"68":{"id":"68","title":"E85 Fuel Capability","fk_module_id":"100030","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"69":{"id":"69","title":"Unleaded Fuel Capability","fk_module_id":"100030","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"70":{"id":"70","title":"26 Gallon Fuel Tank","fk_module_id":"100031","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"71":{"id":"71","title":"36 Gallon Fuel Tank","fk_module_id":"100031","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"72":{"id":"72","title":"Less Garage door opener","fk_module_id":"100032","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"73":{"id":"73","title":"Garage door opener","fk_module_id":"100032","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"74":{"id":"74","title":"Head Restraints Front","fk_module_id":"100033","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"75":{"id":"75","title":"Less Head Restraints Rear","fk_module_id":"100034","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"76":{"id":"76","title":"Head Restraints Rear","fk_module_id":"100034","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"77":{"id":"77","title":"Headlights Standard","fk_module_id":"100035","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"78":{"id":"78","title":"Headlights Auto On\/Off","fk_module_id":"100035","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"79":{"id":"79","title":"Less Height adjustable pedals","fk_module_id":"100036","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"80":{"id":"80","title":"Height adjustable pedals","fk_module_id":"100036","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"81":{"id":"81","title":"Less Limited slip differential rear","fk_module_id":"100037","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"82":{"id":"82","title":"Limited slip differential rear","fk_module_id":"100037","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"83":{"id":"83","title":"1\/2 Ton Load Capacity","fk_module_id":"100038","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"84":{"id":"84","title":"Less Navigation","fk_module_id":"100039","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"85":{"id":"85","title":"Navigation Less Memory","fk_module_id":"100039","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"86":{"id":"86","title":"Navigation Memory","fk_module_id":"100039","updated":"2012-11-16 12:10:23","created":"2012-11-16 12:10:23","comments":"db migration"},"87":{"id":"87","title":"Paint","fk_module_id":"100040","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"88":{"id":"88","title":"Less Parking distance sensors","fk_module_id":"100041","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"89":{"id":"89","title":"Parking distance sensors","fk_module_id":"100041","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"90":{"id":"90","title":"Styleside Box Less Liner","fk_module_id":"100042","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"91":{"id":"91","title":"Styleside Box With Liner","fk_module_id":"100042","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"92":{"id":"92","title":"Power steering","fk_module_id":"100043","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"93":{"id":"93","title":"Less Reading lights front","fk_module_id":"100044","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"94":{"id":"94","title":"Reading lights front","fk_module_id":"100044","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"95":{"id":"95","title":"Less Reading lights rear","fk_module_id":"100045","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"96":{"id":"96","title":"Reading lights rear","fk_module_id":"100045","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"97":{"id":"97","title":"Less Rear seat centre armrest","fk_module_id":"100046","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"98":{"id":"98","title":"Rear seat centre armrest","fk_module_id":"100046","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"99":{"id":"99","title":"Rear view mirror Base","fk_module_id":"100047","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"100":{"id":"100","title":"Rear view mirror Auto","fk_module_id":"100047","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"101":{"id":"101","title":"Rear windscreen Non Heated","fk_module_id":"100048","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"102":{"id":"102","title":"Rear windscreen Heated","fk_module_id":"100048","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"103":{"id":"103","title":"Rear windscreen Electric","fk_module_id":"100048","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"104":{"id":"104","title":"Roll stability control","fk_module_id":"100049","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"105":{"id":"105","title":"Rear Bumper Argent","fk_module_id":"100050","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"106":{"id":"106","title":"Rear Bumper Painted","fk_module_id":"100050","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"107":{"id":"107","title":"Rear Bumper Chrome","fk_module_id":"100050","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"108":{"id":"108","title":"Less Rear Seat","fk_module_id":"100051","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"109":{"id":"109","title":"Rear Seat Base","fk_module_id":"100051","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"110":{"id":"110","title":"Rear Seat Heated","fk_module_id":"100051","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"111":{"id":"111","title":"Less Rear Seat Belts","fk_module_id":"100052","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"112":{"id":"112","title":"Rear Seat Belts","fk_module_id":"100052","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"113":{"id":"113","title":"Less Rear Window Operation","fk_module_id":"100053","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"114":{"id":"114","title":"Rear Window Operation Manual","fk_module_id":"100053","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"115":{"id":"115","title":"Rear Window Operation Electric","fk_module_id":"100053","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"116":{"id":"116","title":"Vinyl Seat Trim","fk_module_id":"100055","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"117":{"id":"117","title":"Cloth Seat Trim","fk_module_id":"100055","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"118":{"id":"118","title":"Premium Cloth Seat Trim","fk_module_id":"100055","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"119":{"id":"119","title":"Leather Seat Trim","fk_module_id":"100055","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"120":{"id":"120","title":"Sports Leather Seat Trim","fk_module_id":"100055","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"121":{"id":"121","title":"3 Seats","fk_module_id":"100056","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"122":{"id":"122","title":"5 Seats","fk_module_id":"100056","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"123":{"id":"123","title":"6 Seats","fk_module_id":"100056","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"124":{"id":"124","title":"Security Less Alarm","fk_module_id":"100057","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"125":{"id":"125","title":"Security With Alarm","fk_module_id":"100057","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"126":{"id":"126","title":"Digital Security With Alarm","fk_module_id":"100057","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"127":{"id":"127","title":"Front Side Airbags","fk_module_id":"100058","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"128":{"id":"128","title":"Front & Rear Side Airbags","fk_module_id":"100058","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"129":{"id":"129","title":"Less Speed limiter","fk_module_id":"100059","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"130":{"id":"130","title":"Speed limiter","fk_module_id":"100059","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"131":{"id":"131","title":"Stability control","fk_module_id":"100060","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"132":{"id":"132","title":"Less Running Boards","fk_module_id":"100061","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"133":{"id":"133","title":"Running Boards","fk_module_id":"100061","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"134":{"id":"134","title":"Power Running Boards","fk_module_id":"100061","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"135":{"id":"135","title":"Urethane Steering Wheel","fk_module_id":"100062","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"136":{"id":"136","title":"Leather Steering Wheel","fk_module_id":"100062","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"137":{"id":"137","title":"Leather Steering Wheel Electric Adj","fk_module_id":"100062","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"138":{"id":"138","title":"Wood\/ Leather Steering Wheel Electric Adj","fk_module_id":"100062","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"139":{"id":"139","title":"Less Sunroof","fk_module_id":"100063","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"140":{"id":"140","title":"Sunroof","fk_module_id":"100063","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"141":{"id":"141","title":"Standard Suspension","fk_module_id":"100064","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"142":{"id":"142","title":"Offroad Suspension","fk_module_id":"100064","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"143":{"id":"143","title":"Sports Suspension","fk_module_id":"100064","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"144":{"id":"144","title":"Trailer stability program","fk_module_id":"100065","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"145":{"id":"145","title":"Interior Trim Pack 1","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"146":{"id":"146","title":"Interior Trim Pack 2","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"147":{"id":"147","title":"Interior Trim Pack 3","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"148":{"id":"148","title":"Interior Trim Pack 4","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"149":{"id":"149","title":"Interior Trim Pack 5","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"150":{"id":"150","title":"Interior Trim Pack 6","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"151":{"id":"151","title":"Interior Trim Pack 7","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"152":{"id":"152","title":"Interior Trim Pack 8","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"153":{"id":"153","title":"Interior Trim Pack 9","fk_module_id":"100066","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"154":{"id":"154","title":"R17 235\/75 Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"155":{"id":"155","title":"R17 255\/65 Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"156":{"id":"156","title":"R17 265\/70 Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"157":{"id":"157","title":"R18 265\/60 Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"158":{"id":"158","title":"R18 275\/65 Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"159":{"id":"159","title":"R17 315\/70 Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"160":{"id":"160","title":"R20 275\/55 A\/S Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"161":{"id":"161","title":"R20 275\/55 A\/T Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"162":{"id":"162","title":"R22 275\/45 Tyre","fk_module_id":"100067","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"163":{"id":"163","title":"Less Underbody Protection","fk_module_id":"100068","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"164":{"id":"164","title":"Underbody Protection","fk_module_id":"100068","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"165":{"id":"165","title":"Sunvisors - Pass Mirror","fk_module_id":"100069","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"166":{"id":"166","title":"Sunvisors Drvr & Pass Mirror","fk_module_id":"100069","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"167":{"id":"167","title":"Sunvisors Drvr & Pass Illum Mirror","fk_module_id":"100069","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"168":{"id":"168","title":"Less Wheel arch extensions","fk_module_id":"100070","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"169":{"id":"169","title":"Wheel arch extensions","fk_module_id":"100070","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"170":{"id":"170","title":"Long Wheelbase","fk_module_id":"100071","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"171":{"id":"171","title":"Medium Wheelbase","fk_module_id":"100071","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"172":{"id":"172","title":"Short Wheelbase","fk_module_id":"100071","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"173":{"id":"173","title":"17x7.5 Steel Type 1","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"174":{"id":"174","title":"17x7.5 Steel Type 2","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"175":{"id":"175","title":"17x7.5 Alloy Type 1","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"176":{"id":"176","title":"17x7.5 Alloy Type 2","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"177":{"id":"177","title":"17x7.5 Alloy Type 3","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"178":{"id":"178","title":"18x7.5 Alloy Type 1","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"179":{"id":"179","title":"18x7.5 Alloy Type 2","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"180":{"id":"180","title":"18x7.5 Alloy Type 3","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"181":{"id":"181","title":"18x7.5 Alloy Type 4","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"182":{"id":"182","title":"17x8.5 Alloy","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"183":{"id":"183","title":"20x8.5 Alloy Type 1","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"184":{"id":"184","title":"20x8.5 Alloy Type 2","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"185":{"id":"185","title":"20x8.5 Alloy Type 3","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"186":{"id":"186","title":"20x8.5 Alloy Type 4","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"187":{"id":"187","title":"20x8.5 Alloy Type 5","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"188":{"id":"188","title":"20x8.5 Alloy Type 6","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"189":{"id":"189","title":"22x9 Alloy","fk_module_id":"100072","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"190":{"id":"190","title":"Standard Spare wheel","fk_module_id":"100073","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"191":{"id":"191","title":"Space Saver Spare wheel","fk_module_id":"100073","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"192":{"id":"192","title":"Standard Windscreen wipers","fk_module_id":"100074","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"193":{"id":"193","title":"Rain Sensing Windscreen wipers","fk_module_id":"100074","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"194":{"id":"194","title":"F150 2012MY Vehicle Line","fk_module_id":"100075","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"195":{"id":"195","title":"Regular Cab","fk_module_id":"100076","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"196":{"id":"196","title":"Extended Cab","fk_module_id":"100076","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"197":{"id":"197","title":"Crew Cab","fk_module_id":"100076","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"198":{"id":"198","title":"XL","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"199":{"id":"199","title":"STX","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"200":{"id":"200","title":"XLT","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"201":{"id":"201","title":"FX2","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"202":{"id":"202","title":"FX4","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"203":{"id":"203","title":"Lariat","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"204":{"id":"204","title":"SVT Raptor","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"205":{"id":"205","title":"King Ranch","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"206":{"id":"206","title":"Platinum","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"207":{"id":"207","title":"Harley-Davidson","fk_module_id":"100077","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"208":{"id":"208","title":"3.7 V6 DOHC MPI","fk_module_id":"100078","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"209":{"id":"209","title":"5.0 V8 DOHC MPI","fk_module_id":"100078","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"210":{"id":"210","title":"6.2 V8 OHC MPI","fk_module_id":"100078","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"211":{"id":"211","title":"6R80 2WD Col Shift","fk_module_id":"100079","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"212":{"id":"212","title":"6R80 4WD Col Shift","fk_module_id":"100079","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"213":{"id":"213","title":"6R80 2WD Col Select Shift","fk_module_id":"100079","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"214":{"id":"214","title":"6R80 4WD Col Select Shift","fk_module_id":"100079","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"215":{"id":"215","title":"6R80 Trans","fk_module_id":"100079","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"216":{"id":"216","title":"6R80 Select Shift Trans","fk_module_id":"100079","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"217":{"id":"217","title":"2WD","fk_module_id":"100080","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"218":{"id":"218","title":"Manual 4WD","fk_module_id":"100080","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"},"219":{"id":"219","title":"Auto 4WD","fk_module_id":"100080","updated":"2012-11-16 12:10:24","created":"2012-11-16 12:10:24","comments":"db migration"}
        };
        var $modules = {
            "1":{"id":"100002","title":"12v power outlet front","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"2":{"id":"100003","title":"12v power outlet rear","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"3":{"id":"100004","title":"Air Conditioning","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"4":{"id":"100005","title":"Ashtray front","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"5":{"id":"100006","title":"Audio","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"6":{"id":"100007","title":"Axle ratio","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"7":{"id":"100008","title":"Brakes","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"8":{"id":"100009","title":"Cigar lighter front seats","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"9":{"id":"100010","title":"Coming home device","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"10":{"id":"100011","title":"Market","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"11":{"id":"100012","title":"Assembly Plant","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"12":{"id":"100013","title":"Cruise control","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"13":{"id":"100014","title":"Cup holders front seats","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"14":{"id":"100015","title":"Cup holders rear seats","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"15":{"id":"100016","title":"Dashboard","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"16":{"id":"100017","title":"descent control system","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"17":{"id":"100018","title":"Differential lock rear","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"18":{"id":"100019","title":"Electronic traction control","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"19":{"id":"100020","title":"Entertainment display screen front","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"20":{"id":"100021","title":"Exterior Mirrors","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"21":{"id":"100022","title":"Floor mats","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"22":{"id":"100023","title":"Front fog lights","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"23":{"id":"100024","title":"Front seat centre armrest","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"24":{"id":"100025","title":"Front Airbags","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"25":{"id":"100026","title":"Front Bumper","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"26":{"id":"100027","title":"Front Seats","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"27":{"id":"100028","title":"Front Seat Belts","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"28":{"id":"100029","title":"Front Window Operation","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"29":{"id":"100030","title":"Fuel","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"30":{"id":"100031","title":"Fuel Tank","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"31":{"id":"100032","title":"Garage door opener","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"32":{"id":"100033","title":"Head Restraints Front","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"33":{"id":"100034","title":"Head Restraints Rear","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"34":{"id":"100035","title":"Headlights","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"35":{"id":"100036","title":"Height adjustable pedals","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"36":{"id":"100037","title":"Limited slip differential rear","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"37":{"id":"100038","title":"Load Capacity","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"38":{"id":"100039","title":"Navigational systems","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"39":{"id":"100040","title":"Paint","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"40":{"id":"100041","title":"Parking distance sensors rear","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"41":{"id":"100042","title":"Second Unit Body","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"42":{"id":"100043","title":"Power steering","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"43":{"id":"100044","title":"Reading lights front","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"44":{"id":"100045","title":"Reading lights rear","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"45":{"id":"100046","title":"Rear seat centre armrest","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"46":{"id":"100047","title":"Rear view mirror","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"47":{"id":"100048","title":"Rear windscreen","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"48":{"id":"100049","title":"Roll stability control","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"49":{"id":"100050","title":"Rear Bumper","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"50":{"id":"100051","title":"Rear Seat","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"51":{"id":"100052","title":"Rear Seat Belts","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"52":{"id":"100053","title":"Rear Window Operation","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"53":{"id":"100054","title":"Rear Windows Tinted","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"54":{"id":"100055","title":"Seat Trim","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"55":{"id":"100056","title":"Seating","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"56":{"id":"100057","title":"Security","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"57":{"id":"100058","title":"Side Airbags","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"58":{"id":"100059","title":"Speed limiter","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"59":{"id":"100060","title":"Stability control","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"60":{"id":"100061","title":"Running Boards","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"61":{"id":"100062","title":"Steering Wheel","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"62":{"id":"100063","title":"Sunroof","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"63":{"id":"100064","title":"Suspension","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"64":{"id":"100065","title":"Trailer stability program","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"65":{"id":"100066","title":"Interior Trim","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"66":{"id":"100067","title":"Tyres","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"67":{"id":"100068","title":"Underbody Protection","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"68":{"id":"100069","title":"Sunvisors","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"69":{"id":"100070","title":"Wheel arch extensions","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"70":{"id":"100071","title":"Wheelbase","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"71":{"id":"100072","title":"Wheels","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"72":{"id":"100073","title":"Spare wheel","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"73":{"id":"100074","title":"Windscreen wipers","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"74":{"id":"100075","title":"Vehicle Line","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"75":{"id":"100076","title":"Cabstyle","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"76":{"id":"100077","title":"Series","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"77":{"id":"100078","title":"Engine","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"78":{"id":"100079","title":"Transmission","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"},"79":{"id":"100080","title":"Drive","fk_program_id":"1","updated":"2012-11-15 13:29:54","created":"2012-11-15 13:29:54","comments":"db migration"}
        };
        
        var $dbObj = new DbMock($assemblies, $modules);
        // Wiring data with JSON mock
        Reg.instance().set('DB', $dbObj, true);
        
        // We create 5 assemblies in 
        $assy1 = new UvmAssembly();
        $assy1.populateById(131); // "Stability control", module: 100060
        
        $assy2 = new UvmAssembly();
        $assy2.populateById(174); // "17x7.5 Steel Type 2" module: 100072
        
        $assy3 = new UvmAssembly();
        $assy3.populateById(190); // "Standard Spare wheel", module: 100073
        
        $assy4 = new UvmAssembly();
        $assy4.populateById(17); // "Brakes", module: 100008
        
        $assy5 = new UvmAssembly();
        $assy5.populateById(154); // "R17 235/75 Tyre", module: 100067
        
        
        $relation = new UvmRelations();
        $relation.getUniqueId();
        
        console.log('----- step 1 ----');
        console.log('Object gets signed with unique and /sticky/ UUID: '+$relation.getUniqueId());
        
        $relation.addRelation($assy1, $assy2, "S");
        $relation.addRelation($assy2, $assy3, "O");
        $relation.addRelation($assy2, $assy4, "S");
        $relation.addRelation($assy2, $assy5, "S");
        
        console.log('----- step 2 ----');
        console.log('Added 5 assemblies related to 5 modules and subsequently created 4 relations');
        
        
        console.log('----- sequence of assemblies (in order of appearance) ----');
        console.log($relation.getAssembliesSequence('string'));
        
        console.log('----- relations of assemblies (in redundant notation from each assembly point of view) ----');
        console.log($relation.getAssembliesRelations('string'));
        
        console.log('----- sequence of modules (in order of appearance) ----');
        console.log($relation.getModulesSequence('string'));
        
        console.log("----- relations of modules (in redundant notation from each module's point of view) ----");
        console.log($relation.getModulesHierarchy('string'));
        
        
        
        console.log($relation);
        
        
        
        
        
        
        
        
       
        // -->
        </script>
    </body>
</html>        
        
        